package com.hl.toolkit.server.tycoin.user.slaverepository;

import com.tycoin.common.repository.AbstractRepository;
import com.tycoin.user.slaveentity.TycoinUserLoginLog;
import org.springframework.cache.annotation.CacheConfig;
import org.springframework.data.jpa.repository.Query;
import org.springframework.data.repository.query.Param;
import org.springframework.stereotype.Repository;

import java.util.List;


@Repository
@CacheConfig(cacheNames = "com.tycoin.user.slaverepository.TycoinUserLoginLogRepository")
public interface TycoinUserLoginLogRepository extends AbstractRepository<TycoinUserLoginLog, Long> {
  
	
	
 	@Query(" select t from TycoinUserLoginLog t where t.userId = :userId  ORDER BY createTime DESC")
	List<TycoinUserLoginLog> findByUserIdAll(@Param("userId") long userId);


	 
 
	
}
